/*
 * @Author: 偻儸小卒[EdisonLiu_]
 * @Date: 2021-06-23 14:57:06
 * @LastEditors: 偻儸小卒[EdisonLiu_]
 * @LastEditTime: 2021-06-24 17:36:53
 * @Description: 
 */
import request from '@/utils/request'
// 查列表
export function fetchList(query) {
	return request({
		url: '/department/list',
		method: 'get',
		params: query
	})
}
// 查分页
export function getListPage(val) {
	return request({
		url: '/department/list?page=' + val,
		method: 'get',
		val
	})
}
// 查对象
export function fetchDepartment(id) {
	return request({
		url: '/department/getinfo',
		method: 'get',
		params: { id }
	})
}
// 创建对象
export function createDepartment(data) {
	return request({
		url: '/department/create',
		method: 'post',
		data
	})
}
// 改对象
export function updateDepartment(data) {
	return request({
		url: '/department/update',
		method: 'post',
		data
	})
}
// 删对象
export function deleteDepartment(data) {
	return request({
		url: '/department/delete',
		method: 'post',
		data
	})
}
